﻿using System;
using System.Collections.Generic;
using System.Windows.Forms;

using StateMachine_Graphical_Editor.Forms;

namespace StateMachine_Graphical_Editor
{
    static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            try
            {              
                WelcomeForm welcomeForm = new WelcomeForm();
                Application.Run(welcomeForm);
                
                if (welcomeForm.Canceled)
                    return;
                else
                {
                    Application.Run(new MainForm(welcomeForm.SelectionMode));
                }
            }
            catch (Exception e)
            {
                MessageBox.Show(e.StackTrace);
            }
        }
    }
}